class BlogsController < ApplicationController
  def show
    @_user = User.find_by_subdomain(params[:sd])
    @current = 'blog'
    render :template => 'blog/index', :layout => 'blog'
  end
  
  def upload_avatar
    user_id = params[:user_id]
    avatar = params[:user][:avatar]
    u = User.find(user_id)
    u.avatar = avatar
    u.save
    redirect_to :back
  end
end